#include <iostream>
#include <vector>
#include <set>
#include <string>
using namespace std;

int countDistinctWord(string str) {  
    int j = str.size();
	int icount = 1;
    for(int i=0;i<j;i++)
    {
       if(str[i]==' ') icount++;
	   }
	   
	return icount;


	//在此处添加相应代码
}

int main() {
	string str = "hello hello wwor world! Ni";
	cout << countDistinctWord(str) << endl;

	return 0;
}